home *** CD-ROM | disk | FTP | other *** search
/ IBM InfoROM for OS/2 Beta 1995 January / IBM InfoROM for OS2 Beta 1-1995.ISO / testcert / storage / function / scsi / add / readlong.scr < prev    next >
Encoding:
Text File  |  1994-08-15  |  1.6 KB  |  56 lines

  1. * Reads the most recent data from the addressed
  2. * logical block ( reads only one block ).
  3. * The data passed is vendor- specific, but shall 
  4. * include the data bytes and the ECC bytes recorded
  5. * on the medium.
  6.  
  7. @THREAD READLONG.LOG
  8. @NEWALIAS SADD SCSIADD.GRA
  9. @IMPORT SCSICOM.SCR
  10. SADD DD_OPEN
  11.  
  12. * 0=Async mode, 1=Sync mode
  13. SADD SET MODE=1
  14.  
  15. * Command completion timeout (Secs)
  16. * 0=the assigned value is the default set by the driver,
  17. * -1=the assigned value is infinite.
  18. SADD SET TIMEOUT=0 
  19.  
  20. SADD SET LABEL = "READ CAPACITY"
  21. SADD READCAPACITY
  22.  
  23. * 0 : read without making any correction
  24. * 1 : data to be corrected by ECC before being transferred
  25. SADD SET ECC_CORRECT = 0
  26.  
  27. * 32bit starting logical block addr
  28. SADD SET LOGICAL_BLOCK_ADDR = 60
  29.  
  30. *STARTING LOGICAL BLOCK ADDR
  31. *SADD RESPONSE $PROMPT="ENTER STARTING LOGICAL BLOCK ADDR : " $RESPONSE=LOGICAL_BLOCK_ADDR $PAUSE=15
  32.  
  33. *  0 = indicates that the logical block address field
  34. *      specifies the first logical block of the range of
  35. *      logical blocks to be operated on by this command.
  36. *  1 = indicates that the logical block address field is
  37. *      a two's complement displacement.  This -ve or +ve
  38. *      displacement shall be added to the logical block
  39. *      address last accessed on the logical unit to form the
  40. *      logical block address for this command.
  41. SADD SET ADDR_MODE=0
  42.  
  43. * No. of bytes to be read
  44. SADD SET NUM_BYTES = 0
  45.  
  46. *NO. OF CONTIGOUS LOGICAL BLOCKS TO BE READ
  47. *SADD RESPONSE $PROMPT="ENTER # OF LOGICAL BLOCKS : " $RESPONSE=NUM_BLOCKS $PAUSE=15
  48.  
  49. * Name for paramblock
  50. SADD SET LABEL = "READ LONG"
  51.  
  52. SADD READ_LONG
  53.  
  54. SADD DD_CLOSE
  55.  
  56.